package com.yzy.demo.test.controller;

import com.yzy.demo.test.service.YzyService;
import com.yzy.demo.test.vo.ResponseBo;
import com.yzy.demo.test.vo.TestQuert;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;

/**
 * @author yangzhenyu
 * */
@Api(value = "测试服务", tags = {"测试服务"})
@RestController
@RequestMapping("api/")
public class YzyController {

    @Autowired
    private HttpServletRequest request;
    @Autowired
    private YzyService service;

    public YzyController() {
    }

    @ApiOperation(value = "微服务调用测试接口")
    @CrossOrigin(origins = "*")
    @PostMapping("/weifuw")
    public ResponseBo weifuw(@RequestBody TestQuert vo){
        return service.weifuw(vo);
    }
}
